alert('start!');

function submitForm(){

    var paramMillion = document.getElementById('million').value;
    var paramKilo = document.getElementById('kilo').value;
    var paramShipId = document.getElementById('shipId').value;
    var url = '/util/carry/num?m=' + paramMillion + '&k=' + paramKilo + '&shipId=' + paramShipId;

    var xmlHttp = new XMLHttpRequest(); //可以放到外面,页面上统一创建一个.
    xmlHttp.open("get", url, true);
    xmlHttp.setRequestHeader("content-type", "application/x-www-form-urlencoded");
    xmlHttp.onreadystatechange = function() {
        if (this.readyState == 4 && this.status == 200) {
            document.getElementById("result").innerHTML = this.responseText;
        }
    };
    xmlHttp.send();
}